Name: Super Mario Bros. 2 Console: Nintendo Version 2.0 05/July/2025 Written by: samurai goroh samuraigoroh@gmail.com ******************************************************************************* ___ _ _ ___ ___ ___ _____ __ ___ _ ___ | __) | | | | | . | | __) | _ | | | / \ | _ | | | | | |__ | | |_| | | __| | _) | _| | | | | | ^^ | | _| | | | | | (___| \___/ |_| |___) |_\_\ |_|_|_| |_/\_| |_\_\ |_| |___| ___ ___ ___ ___ ____ | . ) | _ | | | | __) |__ | | < | _| | | | |__ | _ | __| |___) |_\_\ |___| (___| |_| |____| ******************************************************************************* 1.0 Flags 2.0 Hex Numbers 3.0 Bitwise Values 3.1 Controller Buttons 4.0 Lists ------------------------------------------------------------------------------- SORTED CODES ------------------------------------------------------------------------------- 0000 XXXX Mode/Pointer? (80=in level, 36=transition, 255=slotmachine) 0002 XX Timer level transitions and to initiate Story on title screen 0003 XX Lag Flag & For scrolling text on the Story on title screen 0004 XX initializes story animation 0005 XX X coord - various objects, player, enemy, etc. 0006 XX X coord - various objects, player, enemy, etc. 0007 XX X coord - various objects, player, enemy, etc. 0008 XX Y coord - in horizontal levels, on screen y but reverse order and the 0 line is about mid screen 0009 XX Initiates various on screen level data 000A XX Initiates various on screen level data 000B XX Initiates various on screen level data 000C XX Initiates various on screen level data 000D XX Initiates various on screen level data 000E XX initialize screen transitions 000F XX Misc - player y onscreen on vetical levels, other stuff in horizontal 0010 XX Framerule counter (veggie, birdo eggs, general stuff) 2.0 0011 XX 0012 XX 0013 XX 0014 XX Page of Player's X position 2.0 0015 XX 0016 XX 0017 XX 0018 XX 0019 XX 001A XX 001B XX 001C XX 001D XX 001E XX Page of Player's Y position 2.0 001F XX 0020 XX vertical scroll init (screen wrapping and/or down scrolling) 0021 XX vertical scroll init 0022 XX vertical scroll init 0023 XX vertical scroll init 0024 XX vertical scroll init 0025 XX vertical scroll init 0026 XX vertical scroll init 0027 XX vertical scroll init 0028 XX X coord - Player 2.0 0029 XX X coord - Enemy 05 2.0 002A XX X coord - Enemy 04 2.0 002B XX X coord - Enemy 03 2.0 002C XX X coord - Enemy 02 2.0 002D XX X coord - Enemy 01 2.0 002E XX X coord - Plant 4? 002F XX X coord - Plant 1? 0030 XX X coord - Plant 2? 0031 XX X coord - Plant 3? 0032 XX Y coord - Player 2.0 0033 XX Y coord - Enemy 05 2.0 0034 XX Y coord - Enemy 04 2.0 0035 XX Y coord - Enemy 03 2.0 0036 XX Y coord - Enemy 02 2.0 0037 XX Y coord - Enemy 01 2.0 0038 XX Y coord - Plant 4? 2.0 0039 XX Y coord - Plant 1? 2.0 003A XX Y coord - Plant 2? 2.0 003B XX Y coord - Plant 3? 2.0 003C XX Speed - Player 2.0 003D XX Speed - Enemy 05 2.0 003E XX Speed - Enemy 04 2.0 003F XX Speed - Enemy 03 2.0 0040 XX Speed - Enemy 02 2.0 0041 XX Speed - Enemy 01 2.0 0042 XX Speed - Plant 4? 2.0 0043 XX Speed - Plant 1? 2.0 0044 XX Speed - Plant 2? 2.0 0045 XX Speed - Plant 3? 2.0 0046 XX Jumping Physics - Player 0047 XX Jumping Physics - Enemy 05 0048 XX Jumping Physics - Enemy 04 0049 XX Jumping Physics - Enemy 03 004A XX Jumping Physics - Enemy 02 004B XX Jumping Physics - Enemy 01 004C XX Jumping Physics - Plant 4? 004D XX Jumping Physics - Plant 1? 004E XX Jumping Physics - Plant 2? 004F XX Jumping Physics - Plant 3? 0050 XX Player on a vine/dead (00=False, 01=Vine, 07=Dead) 0051 XX Sprite - Enemy 05(00=None, 01=Visible, 02=Dead) 0052 XX Sprite - Enemy 04 0053 XX Sprite - Enemy 03 0054 XX Sprite - Enemy 02 0055 XX Sprite - Enemy 01 0056 XX Sprite - Plant 4? 0057 XX Sprite - Plant 1? 0058 XX Sprite - Plant 2? 0059 XX Sprite - Plant 3? 005A XX Relation to main character/landscape - Enemy 05 005B XX Relation to main character/landscape - Enemy 04 005C XX Relation to main character/landscape - Enemy 03 005D XX Relation to main character/landscape - Enemy 02 005E XX Relation to main character/landscape - Enemy 01 005F XX Relation to main character/landscape - Plant 4? 0060 XX Relation to main character/landscape - Plant 1? 0061 XX Relation to main character/landscape - Plant 2? 0062 XX Relation to main character/landscape - Plant 3? 00 Not on the ground (could be jumping or being thrown) 04 Walking 05 Turn left because object blocks path 06 Turn right because object blocks path 20 Carrying main character when reaching an edge to turn around 24 Carrying main character with same speed as movement 0063 XX ? 0064 XX ? 0065 XX Sprite Palette, mirroring, etc. - Enemy 05 0066 XX Sprite Palette, mirroring, etc. - Enemy 04 0067 XX Sprite Palette, mirroring, etc. - Enemy 03 0068 XX Sprite Palette, mirroring, etc. - Enemy 02 0069 XX Sprite Palette, mirroring, etc. - Enemy 01 006A XX Sprite Palette, mirroring, etc. - Plant 4? 006B XX Sprite Palette, mirroring, etc. - Plant 1? 006C XX Sprite Palette, mirroring, etc. - Plant 2? 006D XX Sprite Palette, mirroring, etc. - Plant 3? 007X XX Object X Direction 0=not init 1 = right, 2 = left 0085 XX Timer - Invulnerable frames (player) 2.0 0086 XX Timer - ? 0087 XX Timer - Countdown before Bob Omb 1 explodes 2.0 0088 XX Timer - Countdown before Bob Omb 2 explodes 2.0 0089 XX Timer - Countdown before Bob Omb 3 explodes 2.0 008A XX Timer - Countdown before Bob Omb 4 explodes 2.0 008B XX Timer - Countdown before Bob Omb 5 explodes 2.0 008C XX Timer - Countdown before Bomb 1 explodes 2.0 008D XX Timer - Countdown before Bomb 2 explodes 2.0 008E XX Timer - Countdown before Bomb 3 explodes 2.0 008F XX Sprite ID - Character selected 00 - Mario 01 - Princess 02 - Toad 03 - Luigi 0090 XX Sprite ID - Enemy 05 0091 XX Sprite ID - Enemy 04 0092 XX Sprite ID - Enemy 03 0093 XX Sprite ID - Enemy 02 0094 XX Sprite ID - Enemy 01 0096 XXXXXX Item pulled up from ground 0099 XX Graphics for when main character jumps 009A XX Drop through 009B XX Graphics for when main character walks 009C XX Toggle for holding an item 1.0 009D XX Character's facing direction toggle (0=left, 1=right) 00A3 XX Changes once for everytime Tweeter jumps 00AD XX Key held toggle 1.0 00AE XX Height - Item in hand 00B9 XX Timer - Pidget's carpet time left 2.0 00BA XX Screen speed moving left and right 00C7 XX Character's status 00F5 XX Button pressed (Controller 1) 3.1 00F6 XX Button pressed (Controller 2) 3.1 00F7 XX Button held (Controller 1) 3.1 00F8 XX Button held (Controller 2) 3.1 0211 + 0215 Slot machine Slot #1 (only during slot game) 0219 + 021D Slot machine Slot #2 (only during slot game) 0221 + 0225 Slot machine Slot #3 (only during slot game) 09, 09 = Star 01, 03 = Shy Guy 11, 11 = Radish 05, 07 = Cherry 0415 XX Rising of the heart 0416 XX Height of whale's spout after peaking. 0456 XX Timer - Time left Hawkmouth (before Wart) is open 0465 XX HP - Enemy 05 2.0 0466 XX HP - Enemy 04 2.0 0467 XX HP - Enemy 03 2.0 0468 XX HP - Enemy 02 2.0 0469 XX HP - Enemy 01 2.0 04A6 XX Toggle for holding a key? 04AD XX Current number of enemies defeated (to grab a heart) 2.0 04B0 XX Toggle for key being used on door 1.0 04B4 XX Hawkmouth opening / closing width 2.0 04B5 XX Toggle for obtaining the Crystal 1.0 04B6 XX Look into? 04B7 XX Timer - Time left in subspace 2.0 04BD XX Timer - Counts up for how long the door takes to open 2.0 04C2 XX Current hearts in the life meter (High nibble=hearts, 0-based, Low nibble=F) 04C3 XX Number of bars in the life meter (n+2) 2.0 04C4 XX Amount of time left for the screen to shake after POW 2.0 04C5 XX Height to raise and lower the "level" for shake 2.0 04C6 XX Amount of time left for bomb flash in background 2.0 04CA XX Amount of time to build up to charged jump 2.0 04E0 XX Timer - Time left as Starman character 2.0 04E7 XX Area to respawn in 04E8 XX Sub-area to respawn in 04E9 XX Page to respawn in 04EC XX Level Transition 00 Normal game play 01 Begin the same level and area again (like dying revive) 02 Game Over 03 End level, go to bonus game 04 Warp 04ED XX Lives 2.0 04FB XX Toggle for 1st mushroom being pulled 1.0 04FC XX Toggle for 2nd mushroom being pulled 1.0 04FF XX Timer - stop watch 2.0 0531 XX Current level loaded 00 1-1 01 1-2 02 1-3 03 2-1 04 2-2 05 2-3 06 3-1 07 3-2 08 3-3 09 4-1 0A 4-2 0B 4-3 0C 5-1 0D 5-2 0E 5-3 0F 6-1 10 6-2 11 6-3 12 7-1 13 7-2 0546 XX Character - Pickup Speed Animation 1 0547 XX Character - Pickup Speed Animation 2 0548 XX Character - Pickup Speed Animation 3 0549 XX Character - Pickup Speed Animation 4 054A XX Character - Pickup Speed Animation 5 054B XX Character - Pickup Speed Animation 6 054C XX Character - ? 054D XX Character - Standing Jump Height 054E XX Character - Crouching Power Jump Height 054F XX Character - ? 0550 XX Character - Running Jump Height 0551 XX Character - Running Jump Height while carrying object 0552 XX Character - ? 0553 XX Character - Float Timer (set to 0 for everyone but Princess) 0554 XX Character - ? 0555 XX Character - Jumping physics? 05C5 XX Continues 2.0 05EE XX Current music track? 05EF XX Current music track? 0600 XX Loads the current song track 0601 XX Plays a SFX 01 Open Door 04 Shrink/Took Damage 08 Pick Up Grass 80 Death Sound 0602 XX Plays a SFX 0603 XX Plays a SFX / clip of music 0604 XX Character's SFX 0605 XX POW SFX 0606 XX Stores sound effect from $0603 played 0607 XX Stores sound effect from $0602 played 0608 XX Stores sound effect from $0601 played 0609 XX Stores music track from $0600 played 0612 XX Current music tempo 0620 XX Toggle for 1-up being pulled out 1.0 0621 XX Wave after leaving subspace (after grabbing a coin, 02=no more coins) 0628 XX World Selector (0=Outside regular world, 1=Inside caves, etc., 2=Subspace) 0629 XX Possible subspace offset?! 062A XX Cherries 2.0 062B XX Coins (Slot machine currency) 2.0 062C XX BIG vegetables (for stopwatch) 2.0 062D XX levels cleared as Mario 2.0 062E XX levels cleared as Princess 2.0 062F XX levels cleared as Toad 2.0 0630 XX levels cleared as Luigi 2.0 0635 XX Current World number (loads characteristics of world such as Ice) 0638 XX Player's Palette - Overalls 0639 XX Player's Palette - Cap 063A XX Player's Palette - Skin 06F2 XX Mini Status 00 Loading In Or Paused 01 Active Gameplay 02 ? 03 Loading Out 04 ? 05 Character Select/End Level 06F6 XX Character growing/shrinking 06F7 XX Current Level Tileset 10 - Grass 12 - Desert 14 - Sky 16 - Wart's Palace? 06F8 XX Current Cycling Sprite Tileset 06F9 XX Current Character (Appearance, not stats) 00 Big Mario 01 Big Luigi 02 Big Princess 03 Big Toad 04 Small Mario 05 Small Luigi 06 Small Princess 07 Small Toad 06FA XX Current standard sprites (Snifits, Hawkmouth, etc.) 06FB XX Current standard sprites (1-Up, Birdo, etc.) 06FC XX Current changeable sprites (Ostro, Pidget, Pokey, etc.) 06FD XX Current animation of $06F8 (Cycling sprites) 0700 to 07FF Subspace / Jar areas 14CA XX Timer - Crouch jump power (00 to 3C) 2.0 6000 to 83FF Currently Loaded Level/Area/Sub-Area -------------------------------------------------------------------------------- Description -------------------------------------------------------------------------------- 1.0 Flags +--+---+ |00|Off| |01|On | +--+---+ 2.0 Hex Numbers +----+----+-----+ +--------+----+-----+ +----------------+----+-----+ | Bin| Hex| Dec | | Bin | Hex| Dec | | Bin | Hex| Dec | +----+----+-----+ +--------+----+-----+ +----------------+----+-----+ |0000| 0| 0| |00000000| 00| 0| |0000000000000000|0000| 0| |0001| 1| 1| |00010000| 10| 16| |0001000000000000|1000| 4096| |0010| 2| 2| |00100000| 20| 32| |0010000000000000|2000| 8192| |0011| 3| 3| |00110000| 30| 48| |0011000000000000|3000|12288| |0100| 4| 4| |01000000| 40| 64| |0100000000000000|4000|16384| |0101| 5| 5| |01010000| 50| 80| |0101000000000000|5000|20480| |0110| 6| 6| |01100000| 60| 96| |0110000000000000|6000|24576| |0111| 7| 7| |01110000| 70| 112| |0111000000000000|7000|28672| |1000| 8| 8| |10000000| 80| 128| |1000000000000000|8000|32768| |1001| 9| 9| |10010000| 90| 144| |1001000000000000|9000|36864| |1010| A| 10| |10100000| A0| 160| |1010000000000000|A000|40960| |1011| B| 11| |10110000| B0| 176| |1011000000000000|B000|45056| |1100| C| 12| |11000000| C0| 192| |1100000000000000|C000|49152| |1101| D| 13| |11010000| D0| 208| |1101000000000000|D000|53248| |1110| E| 14| |11100000| E0| 224| |1110000000000000|E000|57344| |1111| F| 15| |11110000| F0| 240| |1111000000000000|F000|61440| +----+----+-----+ |11111111| FF| 255| |1111111111111111|FFFF|65535| +--------+----+-----+ +----------------+----+-----+ 3.0 Bitwise Values 3.1 Controller Buttons +--+--------+ |01| Right | |02| Left | |04| Down | |08| Up | |10| Start | |20| Select | |40| B | |80| A | +--+--------+ 4.0 Lists